package composite;

/**
 * @author shenhan
 * @create 2020/4/3 10:54
 * @description
 */
public abstract class OrgComponent {
    private String name;
    private String des;

    protected void add(OrgComponent orgComponent) {
        throw new UnsupportedOperationException();
    }

    protected void remove(OrgComponent orgComponent) {
        throw new UnsupportedOperationException();
    }

    public OrgComponent(String name, String des) {
        this.name = name;
        this.des = des;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDes() {
        return des;
    }

    public void setDes(String des) {
        this.des = des;
    }

    protected abstract void print();

}
